namespace SumerCoreDevOps.Shared.Models.Messages;

/// <summary>
/// 配置变更通知消息
/// </summary>
public class ConfigurationChangedMessage
{
    /// <summary>
    /// 配置键
    /// </summary>
    public string ConfigKey { get; set; } = null!;

    /// <summary>
    /// 新的配置值
    /// </summary>
    public string NewValue { get; set; } = null!;

    /// <summary>
    /// 旧的配置值
    /// </summary>
    public string? OldValue { get; set; }

    /// <summary>
    /// 是否需要重新连接
    /// </summary>
    public bool RequireReconnect { get; set; }

    /// <summary>
    /// 新的服务器地址（如果TCP端口变更）
    /// </summary>
    public string? NewServerAddress { get; set; }

    /// <summary>
    /// 新的TCP端口（如果TCP端口变更）
    /// </summary>
    public int? NewTcpPort { get; set; }

    /// <summary>
    /// 变更描述
    /// </summary>
    public string? Description { get; set; }

    /// <summary>
    /// 通知时间戳（Unix时间戳）
    /// </summary>
    public long Timestamp { get; set; }
}
